#ifndef __GOLD_MANAGER_H__
#define __GOLD_MANAGER_H__
#include "cocos2d.h"

USING_NS_CC;

namespace gofgame
{
	namespace dungeonkeeper
	{
		namespace game
		{
			class GoldManager : public CCNode
			{
			public:
				CC_SYNTHESIZE(int,currentGold,CurrentGold);
				CC_SYNTHESIZE(int,maxGold,MaxGold);
				CC_SYNTHESIZE(float,goldRate,GoldRate);
				CC_SYNTHESIZE(int,rateLv,RateLv);
				CC_SYNTHESIZE(int,startGoldLv,StartGoldLV);
				CC_SYNTHESIZE(int,maxGoldLv,MaxGoldLv);
				CC_SYNTHESIZE(int,goldSystemLv,GoldSystemLv);
				bool initDone;	
				bool isMaxFinish;
			public:
				static GoldManager * shareGoldManager();
				bool init();
				void updateGold(float dt);
				void initData();
				void setGoldManageDataLv(int startLv,int maxLv,int rateLv);
				void startGoldSystem();
				void pauseGoldSystem();
				void stopGoldSystem();
				void resumeGoldSystem();
				void levelUp(int lv);
				void doDefault();
				CCString * getFormatLabelString();
				GoldManager();
				int getNextLv();	
			};
		}
	}
}

#endif //__GOLD_MANAGER_H__
